package org.celstec.mobilegame.client;

import com.google.gwt.user.client.rpc.AsyncCallback;
import com.gwtext.client.widgets.map.Marker;
import com.gwtext.client.widgets.map.LatLonPoint;

public class MapsCallback implements AsyncCallback<LongLatPoint[]>{
	
	public MapsCallback(){
		
	}

	public void onFailure(Throwable caught) {
		
	}

	public void onSuccess(LongLatPoint[] result) {
		for (int i = 0;i< result.length;i++){
			LatLonPoint t = new LatLonPoint(result[i].lat, result[i].lon);
			Marker m = new Marker(t);
			Locatory.mapWidget.addMarker(m);
		}
		
	}

}
